﻿@{
    Layout = null;
}
@helper  getUserName()
{
    Services.User user = Session["user"] as Services.User;
    @Html.Raw(user.Name);
}
@helper  getOtherName()
{
    Services.User user = Session["otheruser"] as Services.User;
    @Html.Raw(user.Name);
}
<!DOCTYPE html>

<html>
<head>
    <meta name="viewport" content="width=device-width" />
    <title></title>
    <link href="~/Resource/Css/Site.css" rel="stylesheet" />
    <link href="~/Resource/Css/smoothness/jquery-ui-1.10.3.custom.min.css" rel="stylesheet" />
    <script src="~/Resource/Js/jquery-1.9.1.js"></script>
    <script src="~/Resource/Js/jquery-ui-1.10.3.custom.min.js"></script>
    <script src="~/Resource/Js/common.js"></script>
</head>
<body id="userlogin_body">
    <div>
        <div class="head">
            <div class="navigation_title" tag="navigation_title" index="1">User Information</div>
            <div index="1" tag="navigation_info" class="navigation_content">
                <div class="navigation_container">
                    <div><a href="/User/UserList">The user information for us</a></div>
                    <div><a href="/Schedule/MyScheduleList">Schedules</a></div>
                </div>
                <div class="navigation_img">
                    <img src="~/Resource/Image/370x208.jpg" />
                    <img src="~/Resource/Image/img.png" />
                </div>
            </div>
            <div class="empty_div"></div>
            <div class="navigation_title" tag="navigation_title" index="2">Choose Action</div>
            <div index="2" tag="navigation_info" class="navigation_content">
                <div class="navigation_container">
                    <div><a href="/ChooseAction/ActionList">Auto Choose Action</a></div>
                </div>
                <div class="navigation_img">
                    <img src="~/Resource/Image/370x208.jpg" />
                    <img src="~/Resource/Image/img.png" />
                </div>
            </div>
            <div class="empty_div"></div>
            <div class="navigation_title" tag="navigation_title" index="3">Wish Menu</div>
            <div index="3" tag="navigation_info" class="navigation_content">
                <div class="navigation_container">
                    <div><a href="#"><span>@getUserName()</span>的愿望菜单</a></div>
                    <div><a href="#"><span>@getOtherName()</span>的愿望菜单</a></div>
                </div>
                <div class="navigation_img">
                    <img src="~/Resource/Image/370x208.jpg" />
                    <img src="~/Resource/Image/img.png" />
                </div>
            </div>
            <div class="empty_div"></div>
            <div class="navigation_title" tag="navigation_title" index="4">Humor Records</div>
            <div index="4" tag="navigation_info" class="navigation_content">
                <div class="navigation_container">
                    <div>Navigation 4-1 </div>
                    <div>Navigation 4-2 </div>
                    <div>Navigation 4-3 </div>
                    <div>Navigation 4-4 </div>
                    <div>Navigation 4-5 </div>
                </div>
                <div class="navigation_img">
                    <img src="~/Resource/Image/370x208.jpg" />
                    <img src="~/Resource/Image/img.png" />
                </div>
            </div>
            <div class="empty_div"></div>
            <div class="navigation_title" tag="navigation_title" index="5">Card Information</div>
            <div index="5" tag="navigation_info" class="navigation_content">
                <div class="navigation_container">
                    <div>Navigation 5-1 </div>
                    <div>Navigation 5-2 </div>
                    <div>Navigation 5-3 </div>
                    <div>Navigation 5-4 </div>
                    <div>Navigation 5-5 </div>
                </div>
                <div class="navigation_img">
                    <img src="~/Resource/Image/370x208.jpg" />
                    <img src="~/Resource/Image/img.png" />
                </div>
            </div>

            <div style="float: right;">
                <div style="float: left; margin-right: 5px;">您好:<span id="span_uname">@getUserName()</span></div>
                <div style="float: right;">[<a href="/Home/Index">退出</a>]</div>
            </div>
        </div>
        <div class="buttom_line">
        </div>

        <div class="contentbody">
            @RenderBody()
        </div>

        <div class="buttom_line">
        </div>
        <div style="clear: both; height: 20px;">
            <div style="float: right; text-align: center; font-weight: bold;">The system to record our love &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color: red">Design by:Peng and Yanxian</span></div>
        </div>
    </div>
</body>
</html>
<script type="text/javascript">
    $(function () {
        $("div[tag=navigation_title]").each(function () {
            this.addEventListener("click", function (e) { e.stopPropagation(); ShowNavigationInfo(this); }, false);
        })

        document.onclick = function (e) {
            $("div[tag=navigation_info]").each(function () {
                $(this).slideUp(500);
            })
        }
    })

    function ShowNavigationInfo(obj) {
        var obj = $(obj);
        $("div[tag=navigation_title]").each(function () {
            if ($(this).attr("index") != obj.attr("index")) {
                $(this).attr("class", "navigation_title");
            }
        })
        obj.attr("class", "navigation_title1");
        $("div[tag=navigation_info]").each(function () {
            if (obj.attr("index") != $(this).attr("index")) {
                $(this).css("display", "none");
            }
        })
        if (obj.next().css("display") == "block") {
            obj.next().slideUp(500, null, function () {
                obj.attr("class", "navigation_title");
            });
        }
        else {
            obj.next().slideDown(500);
        }
    }
</script>
